#include <stdio.h>
int main()
{
	double s=1.0,fac=1.0;
	int i,n;
	printf("input n:");
	scanf("%d",&n);
	for(i=1;i<=n;i++)
	{
		fac=fac*i;
		s=s+1/fac;
	}
	printf("s=%f\n",s);
	return 0;
}